package cn.com.bluemoon.daps.api.model;

import cn.com.bluemoon.daps.api.model.factory.RemoteHandlerStdRelateServiceFallbackFactory;
import cn.com.bluemoon.daps.common.constant.ServiceNameConstants.DapsApiModel;
import cn.com.bluemoon.daps.common.domain.ResultBean;
import cn.com.bluemoon.daps.model.entity.DapDataModelGroup;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import springfox.documentation.annotations.ApiIgnore;

import java.util.List;

/**
 * @author Jarod.Kong
 * @date 2020/12/22 8:28
 */
@FeignClient(value = DapsApiModel.SERVICE, fallbackFactory = RemoteHandlerStdRelateServiceFallbackFactory.class)
@RequestMapping(DapsApiModel.BASE_URI + DapsApiModel.API_MODEL_TABLE_GROUP)
@ApiIgnore
public interface RemoteModelGroupService {

    @GetMapping("/groups")
    @ApiOperation("获取模型分组列表")
    ResultBean<List<DapDataModelGroup>> modelGroups(@RequestParam("modelId") String modelId);
}
